<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>AI工业检测-登录</title>
    <script src="js/jquery-1.11.3.min.js"></script>
    <script src="js/my_ajax.js"></script>
    <style>
        body {background-color: lightyellow; }
        .login {position: fixed;height: 100%; width: 100%; display:flex; flex-direction: column; justify-content: center; align-items: center}
        .user_title {}
        .user {}
        .pwd_title {}
        .pwd {}
        .login_btn {color: blue; cursor: pointer; display:flex; flex-direction: row; justify-content: center; }
        .api {margin-top: 20px;display:flex; flex-direction: row; justify-content: center;}
    </style>
</head>
<body>
    <div class="login">
        <div class="user_title">用户: <input class="user" value="zbzy"></div>
        <div class="pwd_title">口令: <input class="pwd" type="password" value="123456"></div>
        <div class="login_btn">登录</div>
        <div class="api"> <a href="api_test.html">APIs</a></div>
    </div>
    <script>
        $(".login_btn").click(function() {
            var user = $(".user").val();
            var pwd  = $(".pwd").val();
            my_ajax("/user/login", "POST", {user: user, password: pwd}, function() {
                location = "object_browse.html";
            });
        });
    </script>
</body>
</html>